package com.xr.hr;

import com.bstek.dorado.data.*;
import com.bstek.dorado.data.db.SqlDataset;
import com.bstek.dorado.common.*;
import com.xr.common.BusinessTypeVar;
import com.xr.common.CommUtil;

/**
 * datasetListener
 */
public class datasetListener extends AbstractDatasetListener {
  public boolean beforeLoadData(Dataset dataset)
     throws Exception {
		String dsName = dataset.parameters().getString("dsName");
		String sql = "";
			SqlDataset ds = (SqlDataset) dataset;
	       if(dsName != null && dsName.equals("hr_datasetUdeManage")) {
				sql=ds.getSql();
				sql += CommUtil.setConditionSQL(ds)+" "; 
				ds.setSql(sql); 
			}
    return true;
  }

}
